#region Using directives

/*
 * Copyright (c) 2007 Alan Dean.
 * All rights released.
 */

using System;

#endregion

namespace Edenbrook.Telephony
{
    #region Overview
    /// <summary>
    /// Defines the keypad interface.
    /// </summary>
    /// 
    /// <remarks>None</remarks>
    #endregion
    public interface IKeypad
    {
        // properties

        #region int TypingTime
        /// <summary>
        /// When implemented, gets or sets the time taken to type a single character.
        /// </summary>
        /// 
        /// <value>
        /// The time taken to type a single character.
        /// </value>
        /// 
        /// <remarks>None</remarks>
        int TypingTime { get; set; }
        #endregion

        #region int WaitingTime
        /// <summary>
        /// When implemented, gets or sets the time taken to wait for a character to 'fix'.
        /// </summary>
        /// 
        /// <value>
        /// The time taken to wait for a character to 'fix'.
        /// </value>
        /// 
        /// <remarks>
        /// The waiting time is only incurred when the same key needs to used for the next character.
        /// </remarks>
        int WaitingTime { get; set; }
        #endregion

        // methods

        #region int Enter(string)
        /// <summary>
        /// When implemented, returns the time taken to enter the specified <see langword="string"/> <paramref name="value"/>.
        /// </summary>
        /// 
        /// <param name="value">The <see langword="string"/> to enter.</param>
        /// 
        /// <returns>The time taken to enter the specified <see langword="string"/> <paramref name="value"/>.</returns>
        /// 
        /// <remarks>
        /// Every entry costs typing time, but only entries on the same button cost waiting time.
        /// </remarks>
        int Enter(string value);
        #endregion

        #region int Enter(char)
        /// <summary>
        /// When implemented, returns the time taken to enter the specified character <paramref name="value"/>.
        /// </summary>
        /// 
        /// <param name="value">The character to enter.</param>
        /// 
        /// <returns>The time taken to enter the specified character <paramref name="value"/>.</returns>
        /// 
        /// <remarks>
        /// Every entry costs typing time, but only entries on the same button cost waiting time.
        /// </remarks>
        int Enter(char value);
        #endregion
    }
}